﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using RPGXEngine.IO;

namespace RPGXEngine.Factories
{
    public static class TextFileLoaderFactory
    {
        #region Static Properties

        public static ITextFileLoader TextFileLoader
        {
            get { return TextFileLoaderFactory._textFileLoader; }
            set { TextFileLoaderFactory._textFileLoader = value; }
        }
        private static ITextFileLoader _textFileLoader = null;

        #endregion

        #region Public Static Methods

        public static void Set(ITextFileLoader loader)
        {
            TextFileLoaderFactory.TextFileLoader = loader;
        }

        public static ITextFileLoader Get()
        {
            return TextFileLoaderFactory.TextFileLoader ?? new TextFileLoader();
        }

        #endregion
    }
}
